package notes.interview.saved;

public class T0002_singleton4 {

	// 单例模式，懒汉式，最简单的方式采用内部类
	private T0002_singleton4() {}
	
	// 静态内部类，不会随着外部类的创建而初始化
	private static class Inner{
		private static final T0002_singleton4 INSTANCE = new T0002_singleton4();
	}
	
	public T0002_singleton4 getInstance() {
		return Inner.INSTANCE;
	}
}
